-- GENERATED SPELL FOR [Maexxna Spiderling] --


function spell0_17055(pUnit, Event) --@Necrotic Poison,Heal--
pUnit:FullCastSpellOnTarget(28776,pUnit)
pUnit:RegisterEvent('Sorts_17055', 30313, 1)
end

function spell1_17055(pUnit, Event) --@Necrotic Poison,Heal--
pUnit:FullCastSpellOnTarget(54121,pUnit)
pUnit:RegisterEvent('Sorts_17055', 30339, 1)
end

function Sorts_17055(pUnit, Event)
local choix_sorts_17055 = math.random(0, 1)
if choix_sorts_17055 == 0 then
pUnit:RegisterEvent('spell0_17055', 1, 1)
end
if choix_sorts_17055 == 1 then
pUnit:RegisterEvent('spell1_17055', 1, 1)
end
end

function mob17055_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_17055', math.random(1500, 3000), 1)
end

function mob17055_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17055_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17055_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(17055, 1, 'mob17055_Action')
RegisterUnitEvent(17055, 2, 'mob17055_Leave')
RegisterUnitEvent(17055, 3, 'mob17055_Kill')
RegisterUnitEvent(17055, 4, 'mob17055_Die')
